package cn.szzsi.business.service;

import cn.szzsi.core.kit.CommonUtil;
import cn.szzsi.model.AgentBalanceDetail;
import com.jfinal.kit.StrKit;

import java.math.BigDecimal;
import java.util.Date;

public class AgentBalanceDetailService {
    public static final AgentBalanceDetailService service=new AgentBalanceDetailService();

    /**
     *
     * @param agentId
     * @param addMoney
     * @param type
     * @param bankType
     * @param cashingAccount
     * @param cashingStatus
     * @param remark
     */
    public void saveInfo(String agentId, BigDecimal addMoney,Integer type,Integer bankType,String cashingAccount,Integer cashingStatus,String remark){
        AgentBalanceDetail abd=new AgentBalanceDetail();
        abd.setId(StrKit.getRandomUUID());
        abd.setAgentId(agentId);
        abd.setAddMoney(addMoney);
        abd.setType(type);
        abd.setBankType(bankType);
        abd.setCashingAccount(cashingAccount);
        abd.setCashingStatus(cashingStatus);
        abd.setRemark(remark);
        abd.setCreateDate(new Date());
        abd.save();
    }
}
